package com.longcai.piaojia.conn;

import com.zcx.helper.http.AsyCallBack;
import com.zcx.helper.http.note.HttpInlet;

import org.json.JSONObject;

/**
 * Created by Administrator on 2016/10/14.
 */
@HttpInlet(Conn.ORDER_GENERATENUMBER)
public class RechargeOrderNumGet extends BaseAsyGet<String> {

    public RechargeOrderNumGet(AsyCallBack<String> asyCallBack) {
        super(asyCallBack);
    }

    @Override
    protected String parser(JSONObject object) throws Exception {

        TOAST = object.optString("message");

        if (object.optInt("code") == 200) {

            return object.optString("order_number");

        }

        return null;
    }
}
